import type { AppEnvironment } from './types'

import {
    apiServerDefault,
    webSocketServerDefault,
    mqttServerDefault,
} from './network-hosts/hosts._default'

import {
    apiServer,
    webSocketServer,
    mqttServer,
} from './network-hosts/hosts.production'

import {
    evaluateFullHost,
} from './network-hosts/utils'

const appEnvironment: AppEnvironment = {
    isProduction: true,

    envName: {
        humanFriendly: '',
        scriptSafe: 'env-prod',
    },

    networkHosts: {
        apiServer1:       evaluateFullHost<'http:'>(apiServer,       apiServerDefault),
        webSocketServer1: evaluateFullHost<'ws:'  >(webSocketServer, webSocketServerDefault),
        mqttServer1: evaluateFullHost<'ws:'  >(mqttServer, mqttServerDefault),
    },
}

export default appEnvironment
